#pragma once

#include "ThinWorkerThread.h"

class CCmdQueue;

class CSaveNewBagInfo: public CThinWorkerThread
{
public:

	CSaveNewBagInfo(void);
	virtual ~CSaveNewBagInfo(void);

public:

	void SaveNewBagInfoToDB(LPCTSTR szPrn, LPCTSTR szUserID, LPCTSTR szBID = NULL);

protected:

	 virtual DWORD ThreadMemberFunc();

protected:

	enum
	{
		MAX_PRN_LENGTH		= 64,
		MAX_USER_ID_LENGTH	= 256,
		MAX_BID_LENGTH		= 256,
	};

	typedef struct tagNewBagInfo
	{
		wchar_t szPrn[MAX_PRN_LENGTH];
		wchar_t szUserID[MAX_USER_ID_LENGTH];
		wchar_t szBID[MAX_BID_LENGTH];
		tagNewBagInfo()
		{
			memset(szPrn, 0, sizeof(wchar_t) * MAX_PRN_LENGTH);
			memset(szUserID, 0, sizeof(wchar_t) * MAX_USER_ID_LENGTH);
			memset(szBID, 0, sizeof(wchar_t) * MAX_BID_LENGTH);
		}

	}NewBagInfo;

	CCmdQueue*	m_pCmdQueue;
};

